package ch00.a9;


/**
 * @description: 类描述
 * @author: Fesine
 * @createTime:2016/7/12 23:41
 * @update:修改内容
 * @author: Fesine
 * @updateTime:2016/7/12 23:41
 */
public class Test {
    public static void main(String[] args) {
        Animal[] animals = new Animal[5];
        animals[0] = new Cat("小花");
        animals[1] = new Dog("小黑");
        animals[2] = new Cattle("阿毛");
        animals[3] = new Sheep("咪咪");
        animals[4] = new Cat("姊姊");
        for (Animal animal : animals) {
            System.out.println(animal.shout());
        }
    }
}
